<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
	<script type="text/javascript" src="js/jquery-1.12.4.js"></script>
	<script type="text/javascript">
	$(function(){
		$("th").css("background","#ff000066");
		
		$("table tr:even").css("background","#ffeb3bb8");
	})
	</script>
	<div align="center">
		<form action="PetListServlet" method="post">
			品种&nbsp;&nbsp;<select name="petBreed">
				<option value="0">--请选择--</option>
				<option value="1">狗</option>
				<option value="2">猫</option>
				<option value="3">鸟</option>
				<option value="4">兔</option>
			</select>&nbsp;&nbsp;<input type="submit" value="查询">&nbsp;&nbsp;<a
				href="petAdd.jsp">新增宠物</a>
			<table align="center" border="1">
				<tr>
					<th align="center">宠物昵称</th>
					<th align="center">出生日期</th>
					<th align="center">性别</th>
				</tr>
				<c:forEach var="pet" items="${requestScope.list}">
					<tr>
						<td>${pet.petName }</td>
						<td>${pet.birtHday }</td>
						<c:if test="${pet.petSex ==1}">
							<td>雄</td>
						</c:if>
						<c:if test="${pet.petSex ==2}">
							<td>雌</td>
						</c:if>
					</tr>
				</c:forEach>
			</table>
		</form>
	</div>
</body>
</html>